<%@page import="cn.sbgs.www.common.Constant"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE HTML>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <title>书画经营有限公司</title>
    <link href="css/global.css" rel="stylesheet" type="text/css">
    <link href="css/index.css" rel="stylesheet" type="text/css">
    <link href="bt/css/bootstrap.min.css" rel="stylesheet" >
    <style>  
		#marquee1 {top:50px;width:980px;height:500px;overflow:hidden;float:left; margin-left:5px;}
		#marquee1 ul li {float:left;padding:0 4px; }
		#marquee1 ul li img {display:block;}
   </style>
<script type="text/javascript"
	src="<%=request.getContextPath()%>/js/jquery-1.7.1.js"></script>
	<script type="text/javascript">
	  $(function(){
	      $.ajax( {
					type : "POST",
					url : "<%=request.getContextPath()%>/client/news/getIndexNews.do",
					dataType: "json",
					async : false,
					success : function(data) {
					  if(data.code=="0000"){
					     /***关于我们**/
					     var intro="<a href='<%=request.getContextPath()%>/aboutus.jsp'>"+data.newsBean.intro+"</a>";
					     $("#intro").html(intro);
                          if(data.newsBean.col1 != null && data.newsBean.col1 != '' ){
                              $('#banner').attr('src','<%=Constant.Url1158%>'+data.newsBean.col1);
                          }
                          $("#downloadImg").html('<img src="<%=Constant.Url1158%>/'+data.newsBean.col2+'">');
                          $("#weixinImg").html('<img src="<%=Constant.Url1158%>/'+data.newsBean.col3+'">');
					     /**推荐作品**/
					     var works="";
					     for(var i=0 ;i<data.workBeans.length;i++){
//					       works+="<li>";
					       works+="<a href='<%=request.getContextPath()%>/client/news/getWorksDetail.do?worksid="+data.workBeans[i].workid+"'>";
					       works+="<p><img src='<%=Constant.Url1158%>/"+data.workBeans[i].workPic+"' class='img-rounded pull-xs-left' style='height: auto; width: 200px'></p>";
//					       works+="<span>"+data.workBeans[i].workName+"</span>";
					       works+="</a>";
//					       works+="</li>";
					     }
					      $("#works").html(works);
					      /***资讯**/
					      var news="<dl>";
					      news+="<dt><h4>最新资讯</h4><span><a href='<%=request.getContextPath()%>/client/news/getNewsBeans.do'></a></span></dt>";
					       for(var i=0 ;i<data.newsBeans.length;i++){
					       news+="<dd>";
					       news+="<a href='<%=request.getContextPath()%>/client/news/getNewsDetail.do?newsid="+data.newsBeans[i].id+"' >";
					       news+="<p>"+data.newsBeans[i].title+"</p>";
//					       news+="<span>"+data.newsBeans[i].createtime+"</span>";
					       news+="</a>";
					       news+="</li>";
					     }
					     news+="</dl>";
					     $("#news").html(news);
					     /**友情链接*/
					     var links="";
					       for(var i=0 ;i<data.linkBeans.length;i++){
					       links+="<li>";
					       links+="<a href='"+data.linkBeans[i].url+"'>";
					       links+="<img src='"+data.linkBeans[i].pic+"' style='width:181px;height:87px;'/>";
					       links+="</a>";
					       links+="</li>";
					     }
					     $("#links").html(links);
                          /**联系我们*/
                          $("#tellus").html(data.newsBean2.content);

					     
			       }else{
			           alert(data.code+data.codeMsg);
			       }
					}
			  });  
			
	  });
	</script>
</head>

<body>
    <!--头部开始-->
    <div class="bannercon">
        <div class="banner">
            <img src="image/indexbanner.jpg" id="banner">
        </div>
    </div>
    <!--正文开始-->
    <div class="maincon">
        <div class="main">
            <div class="navcon">
                <ul>
                    <li>
                        <a href="/" class="currentA">首页</a>
                    </li>
                    <li>
                        <a href="<%=request.getContextPath()%>/client/news/getActivitylist.do">活动</a>
                    </li>
                    <li>
                        <a href="<%=request.getContextPath()%>/client/news/getHdlist.do">互动</a>
                    </li>
                    <li>
                        <a href="<%=request.getContextPath()%>/client/news/getSchoolList.do">名校</a>
                    </li>
                    <li>
                        <a href="<%=request.getContextPath()%>/client/news/mentorship.do">师友</a>
                    </li>
                    <li>
                        <a href="<%=request.getContextPath()%>/client/news/getMagazineList.do">杂志</a>
                    </li>
                </ul>
            </div>
            <div class="section1">
                <div class="contain clear">
                    <div id="news">

                    </div>
                    <div class="productshow no-margin">
                        <dl>
                            <dt><h4>作品展示</h4><span><a href="<%=request.getContextPath()%>/client/news/getWorklist.do"></a></span></dt>
                            <div  id="marquee1" >
                                <div class="row">
                                    <div class="col-md-12">
                                        <ul id="works">

                                        </ul>
                                    </div>
                                </div>

                            </div>
                        </dl>
                    </div>
                </div>

            </div>
        </div>
    </div>
    <!--主体结束-->
    <!--footer-->
    <div class="footercon">
        <div class="container-fluid">
            <div class="row">
                <div class="col-md-12" style="background-color: #002a80;height: 250px">
                    <div class="section1">
                        <div class="row" style="width: 1000px;margin: 0 auto;line-height: 40px;">
                            <div class="col-md-4">
                                <div class="row">
                                    <div class="col-md-12">
                                        <strong style="font-size: 20px;color: white;font-family:  '新宋体'">更多精彩内容</strong>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-md-6">
                                        <div id="downloadImg"></div>
                                    </div>
                                    <div class="col-md-6">
                                        <div class="row" style="position: absolute;top: 12px">
                                            <div class="col-md-12">
                                                <input type="button" style="filter: alpha(opacity=45); opacity:0.45; width: 140px;height: 40px">
                                                <strong style="position:absolute;left: 25px;top: 2px;font-size: 17px;font-weight:bolder;color: white;font-family:  '新宋体'">Android版下载</strong>
                                            </div>
                                        </div>
                                        <div class="row" style="position: absolute;top: 80px">
                                            <div class="col-md-12" >
                                                <input type="button" style="filter: alpha(opacity=45); opacity:0.45; width: 140px;height: 40px">
                                                <strong style="position:absolute;left: 25px;top: 2px;font-size: 17px;font-weight:bolder;color: white;font-family:  '新宋体'">iPhone版下载</strong>
                                            </div>

                                        </div>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-md-12">
                                        <strong style="font-size: medium;color: white">扫描二维码,下载手机客户端</strong>
                                    </div>
                                </div>
                            </div>
                            <div class="col-md-4">
                                <div class="row">
                                    <div class="col-md-12">
                                        <strong style="font-size: 20px;color: white;font-family:  '新宋体'">微信公众号 ： </strong><strong style="font-size: 20px;color:orange;font-family:  '新宋体'">青少年书法</strong>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-md-12">
                                        <div id="weixinImg"></div>
                                    </div>
                                </div>
                            </div>
                            <div class="col-md-4">
                                <div class="row">
                                    <div class="col-md-12">
                                        <div id="tellus" style="position:absolute;top:20px;font-size: 15px;color:darkgray;line-height: 25px;font-family:  '新宋体'"></div>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-md-12">
                                        <strong style="position: absolute;top: 180px;font-size: 10px;color:#2d6987;font-family:  '新宋体'">青少年书法&nbsp;版权所有2013-2013&nbsp;ICP备8888888号</strong>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>

                </div>
            </div>
        </div>

    </div>
</body>
	<script type="text/javascript" src="<%=request.getContextPath()%>/js/kxbdSuperMarquee.js"></script>
    <script type="text/javascript" src="bt/js/bootstrap.min.js"></script>
	<script type="text/javascript">
	  $(function(){
	        //一次横向滚动一个
			$('#marquee1').kxbdSuperMarquee({
				distance:160,
				time:3,
				direction:'left'
			});
	   
	  });
	</script>
</html>
